<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>导航条</title>
    <link rel="stylesheet" href="./css/reset.css">
    
    <style>
        body{
            height: 3000px;
        }
        .menu{
            width: 1210px;
            height: 48px;
            background-color:#bfa;

            margin: 100px auto;

            position: sticky;
            top: 0;
        }
        .menu li{
            float: left;
            /* height: 48px; */
            line-height: 48px;
        }
        .menu a{
            display: block;
            text-decoration: none;
            color: #777;
            font-size: 16px;
            padding: 0 44px;
        }
        a:hover{
            background-color: red;
        }
    </style>
    
</head>
<body>
    <ul class="menu">
        <li>
            <a href="#">HTML/CSS</a>
        </li>
        <li>
            <a href="#">Borwser Side</a>
        </li>
        <li>
            <a href="#">Server Side</a>
        </li>
        <li>
            <a href="#">Programming</a>
        </li>
        <li>
            <a href="#">XML</a>
        </li>
        <li>
            <a href="#">Web Building</a>
        </li>
        <li>
            <a href="#">Reference</a>
        </li>
    </ul>
</body>
</html>